<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>
<head>
	<title>E8NET</title>
	<meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <!-- bootstrap -->
<link href="/xqkq/Public/Admin/css/bootstrap/bootstrap.css" rel="stylesheet" />
<link href="/xqkq/Public/Admin/css/bootstrap/bootstrap-responsive.css" rel="stylesheet" />
<link href="/xqkq/Public/Admin/css/bootstrap/bootstrap-overrides.css" type="text/css" rel="stylesheet" />

<!-- global styles -->
<link rel="stylesheet" type="text/css" href="/xqkq/Public/Admin/css/layout.css" />
<link rel="stylesheet" type="text/css" href="/xqkq/Public/Admin/css/elements.css" />
<link rel="stylesheet" type="text/css" href="/xqkq/Public/Admin/css/icons.css" />

<!-- libraries -->
<link href="/xqkq/Public/Admin/css/lib/bootstrap-wysihtml5.css" type="text/css" rel="stylesheet" />
<link href="/xqkq/Public/Admin/css/lib/jquery-ui-1.10.2.custom.css" rel="stylesheet" type="text/css" />
<link href="/xqkq/Public/Admin/css/lib/font-awesome.css" type="text/css" rel="stylesheet" />
<link href="/xqkq/Public/Admin/css/lib/morris.css" type="text/css" rel="stylesheet" />



<!-- open sans font -->
<link href='http://fonts.useso.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css' />

<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->

<link href="/xqkq/Public/Libs/confirm/jquery.confirm.css" type="text/css" rel="stylesheet" />


    <link rel="stylesheet" href="/xqkq/Public/Admin/css/compiled/tables.css" type="text/css" media="screen" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body>

    <!-- navbar -->
<div class="navbar navbar-inverse">
    <div class="navbar-inner">
        <button type="button" class="btn btn-navbar visible-phone" id="menu-toggler">
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
        </button>

        <a class="brand" href="index.html"><img src="/xqkq/Public/Admin/img/logo.png" /></a>

        <ul class="nav pull-right">
            <li class="hidden-phone">
                <input class="search" type="text" />
            </li>

            <!-- 未处理提醒-->
            <li class="notification-dropdown hidden-phone">
                <a href="#" class="trigger">
                    <i class="icon-warning-sign"></i>
                    <span class="count">8</span>
                </a>
                <div class="pop-dialog">
                    <div class="pointer right">
                        <div class="arrow"></div>
                        <div class="arrow_border"></div>
                    </div>
                    <div class="body">
                        <a href="#" class="close-icon"><i class="icon-remove-sign"></i></a>
                        <div class="notifications">
                            <h3>You have 6 new notifications</h3>
                            <a href="#" class="item">
                                <i class="icon-signin"></i> New user registration
                                <span class="time"><i class="icon-time"></i> 13 min.</span>
                            </a>
                            <a href="#" class="item">
                                <i class="icon-signin"></i> New user registration
                                <span class="time"><i class="icon-time"></i> 18 min.</span>
                            </a>
                            <a href="#" class="item">
                                <i class="icon-envelope-alt"></i> New message from Alejandra
                                <span class="time"><i class="icon-time"></i> 28 min.</span>
                            </a>
                            <a href="#" class="item">
                                <i class="icon-signin"></i> New user registration
                                <span class="time"><i class="icon-time"></i> 49 min.</span>
                            </a>
                            <a href="#" class="item">
                                <i class="icon-download-alt"></i> New order placed
                                <span class="time"><i class="icon-time"></i> 1 day.</span>
                            </a>
                            <div class="footer">
                                <a href="#" class="logout">View all notifications</a>
                            </div>
                        </div>
                    </div>
                </div>
            </li>

            <!-- 消息提醒 -->
            <li class="notification-dropdown hidden-phone">
                <a href="#" class="trigger">
                    <i class="icon-envelope-alt"></i>
                </a>
                <div class="pop-dialog">
                    <div class="pointer right">
                        <div class="arrow"></div>
                        <div class="arrow_border"></div>
                    </div>
                    <div class="body">
                        <a href="#" class="close-icon"><i class="icon-remove-sign"></i></a>
                        <div class="messages">
                            <a href="#" class="item">
                                <img src="img/contact-img.png" class="display" />
                                <div class="name">Alejandra Galván</div>
                                <div class="msg">
                                    There are many variations of available, but the majority have suffered alterations.
                                </div>
                                <span class="time"><i class="icon-time"></i> 13 min.</span>
                            </a>
                            <a href="#" class="item">
                                <img src="img/contact-img2.png" class="display" />
                                <div class="name">Alejandra Galván</div>
                                <div class="msg">
                                    There are many variations of available, have suffered alterations.
                                </div>
                                <span class="time"><i class="icon-time"></i> 26 min.</span>
                            </a>
                            <a href="#" class="item last">
                                <img src="img/contact-img.png" class="display" />
                                <div class="name">Alejandra Galván</div>
                                <div class="msg">
                                    There are many variations of available, but the majority have suffered alterations.
                                </div>
                                <span class="time"><i class="icon-time"></i> 48 min.</span>
                            </a>
                            <div class="footer">
                                <a href="#" class="logout">View all messages</a>
                            </div>
                        </div>
                    </div>
                </div>
            </li>


            <!-- 个人菜单 -->
            <li class="dropdown">
                <a href="#" class="dropdown-toggle hidden-phone" data-toggle="dropdown">
                    Your account
                    <b class="caret"></b>
                </a>
                <ul class="dropdown-menu">
                    <li><a href="personal-info.html">Personal info</a></li>
                    <li><a href="#">Account settings</a></li>
                    <li><a href="#">Billing</a></li>
                    <li><a href="#">Export your data</a></li>
                    <li><a href="#">Send feedback</a></li>
                </ul>
            </li>

            <!-- 网站设置 -->
            <li class="settings hidden-phone">
                <a href="personal-info.html" role="button">
                    <i class="icon-cog"></i>
                </a>
            </li>

            <!-- 前台首页 -->
            <li class="settings hidden-phone">
                <a href="signin.html" role="button">
                    <i class="icon-share-alt"></i>
                </a>
            </li>
        </ul>
    </div>
</div>
<!-- end navbar -->
    <!-- sidebar -->
<div id="sidebar-nav">
    <ul id="dashboard-menu">

        <?php if(is_array($menu)): $i = 0; $__LIST__ = $menu;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$m): $mod = ($i % 2 );++$i;?><li class="<?php echo ($m["active"]); ?>">

                <?php if($m["active"] == 'active'): ?><div class="pointer">
                        <div class="arrow"></div>
                        <div class="arrow_border"></div>
                    </div><?php endif; ?>

                <a <?php if($m["child"] != ''): ?>class="dropdown-toggle"<?php endif; ?>  href="<?php echo ($m["url"]); ?>">
                    <i class="<?php echo ($m["icon"]); ?>"></i>
                    <span><?php echo ($m["text"]); ?></span>
                    <?php if($m["child"] != ''): ?><i class="icon-chevron-down"></i><?php endif; ?>
                </a>

                <?php if($m["child"] != ''): ?><ul class="<?php echo ($m["active"]); ?> submenu">
                        <?php if(is_array($m["child"])): $i = 0; $__LIST__ = $m["child"];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$c): $mod = ($i % 2 );++$i;?><li><a href="<?php echo ($c["url"]); ?>" class="<?php echo ($c["active"]); ?>"><?php echo ($c["text"]); ?></a></li><?php endforeach; endif; else: echo "" ;endif; ?>
                    </ul><?php endif; ?>
            </li><?php endforeach; endif; else: echo "" ;endif; ?>

    </ul>
</div>
<!-- end sidebar -->


	<!-- main container -->
    <div class="content">

        <div class="container-fluid">
            <div id="pad-wrapper">

                <!-- users table -->
                <div class="table-wrapper users-table section">
                    <div class="row-fluid head">
                        <div class="span12">
                            <h4>院系管理员管理</h4>
                        </div>
                    </div>

                    <div class="row-fluid filter-block">
                        <div class="pull-right">
                            <div class="ui-select" style="margin-top: -2px;">
                                <select onchange="changeD($(this).val())">
                                    <option value="" /> 所有院系管理员
                                    <?php if(is_array($departmentList)): $i = 0; $__LIST__ = $departmentList;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$department): $mod = ($i % 2 );++$i;?><option <?php if($did == $department['id']): ?>selected<?php endif; ?> value="<?php echo ($department["id"]); ?>" /> <?php echo ($department["name"]); endforeach; endif; else: echo "" ;endif; ?>
                                </select>
                            </div>
                            <a href="<?php echo U('Dadmin/add');?>" class="btn-flat pull-right success new-product add-user">+ 添加院系管理员</a>
                        </div>
                    </div>

                    <div class="row-fluid">
                        <table class="table table-hover">
                            <thead>
                            <tr>
                                <th class="span1">ID</th>
                                <th class="span4">
                                    账号/姓名
                                </th>
                                <th class="span3">
                                    <span class="line"></span>所属系别
                                </th>
                                <th class="span2">
                                    <span class="line"></span>LAST LOGIN TIME
                                </th>
                                <th class="span3">
                                    <span class="line"></span>LAST LOGIN IP
                                </th>
                                <th class="span2 align-right">
                                    <span class="line"></span>ACTION
                                </th>
                            </tr>
                            </thead>
                            <tbody>
                            <?php if(is_array($dadminList)): $i = 0; $__LIST__ = $dadminList;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$dadmin): $mod = ($i % 2 );++$i;?><tr>
                                    <td><?php echo ($dadmin["id"]); ?></td>
                                    <td>
                                        <img src="/xqkq/Public/Admin/img/contact-img.png" class="img-circle avatar hidden-phone" />
                                        <a href="#" class="name"><?php echo ($dadmin["account"]); ?> / <?php echo ($dadmin["email"]); ?></a>
                                        <span class="subtext"><?php echo ($dadmin["tname"]); ?></span>
                                    </td>
                                    <td><?php echo ($dadmin["dname"]); ?></td>
                                    <td><?php echo ($dadmin["last_login_time"]); ?></td>
                                    <td><?php echo ($dadmin["last_login_ip"]); ?></td>
                                    <td class="align-right">
                                        <a href="<?php echo U('Dadmin/edit',array('id'=>$department['id']));?>">编辑</a>&nbsp;&nbsp;
                                        <a href="javascript:void(0);" onclick="return delConfirm('/xqkq/admin.php/Dadmin/del/id/<?php echo ($term["id"]); ?>','对应管理员将被删除')">删除</a>
                                    </td>
                                </tr><?php endforeach; endif; else: echo "" ;endif; ?>
                            </tbody>
                        </table>
                    </div>
                </div>
                <!-- end users table -->

                <div class="row ctrls">
                    <div class="pagination pull-right">
                        <ul>
                            <?php echo ($page); ?>
                        </ul>
                    </div>
                </div>

            </div>
        </div>
    </div>
    <!-- end main container -->

	<!-- scripts for this page -->
<script src="/xqkq/Public/Admin/js/wysihtml5-0.3.0.js"></script>
<script src="/xqkq/Public/Admin/js/jquery-latest.js"></script>
<script src="/xqkq/Public/Admin/js/bootstrap.min.js"></script>
<script src="/xqkq/Public/Admin/js/bootstrap-wysihtml5-0.0.2.js"></script>
<script src="/xqkq/Public/Admin/js/jquery-ui-1.10.2.custom.min.js"></script>
<!-- knob -->
<script src="/xqkq/Public/Admin/js/jquery.knob.js"></script>
<!-- flot charts -->
<script src="/xqkq/Public/Admin/js/jquery.flot.js"></script>
<script src="/xqkq/Public/Admin/js/jquery.flot.stack.js"></script>
<script src="/xqkq/Public/Admin/js/jquery.flot.resize.js"></script>
<!-- morrisjs -->
<script src="/xqkq/Public/Admin/js/raphael-min.js"></script>
<script src="/xqkq/Public/Admin/js/morris.min.js"></script>
<!-- call all plugins -->
<script src="/xqkq/Public/Admin/js/theme.js"></script>

<script src="/xqkq/Public/Admin/js/tools.js"></script>
<script src="/xqkq/Public/Libs/confirm/jquery.confirm.js"></script>


    <script>
        function changeD(id) {
//            $.post("<?php echo U('Dadmin/Index',array('did'=>" + id + "));?>",{},function(result){
//                location.reload();
//            })
            window.location.href = "/xqkq/admin.php/Dadmin/Index/did/" + id;
        }
    </script>

</body>
</html>